Search found 25 matches

by LEEDNH
Wed Apr 21, 2021 12:53 am
Forum: Modules
Topic: I2C SCANNER
Replies: 13
Views: 658

Re: I2C SCANNER

HI JERRY, Yes we are getting good results. Due to your guidance. Left on my own, I would be going in circles of ever increasing radii. I do very much appreciate your help! I had tried the shift instruction as Z = Z >> 3 TAKE Z SHIFT IT 3 X RIGHT AND STICK IT BACK INTO Z (KIND OF LIKE IN C) BUT I GOT...
by LEEDNH
Tue Apr 20, 2021 6:41 am
Forum: Modules
Topic: I2C SCANNER
Replies: 13
Views: 658

Re: I2C SCANNER

THE CODE MAY BE READY FOR A TEST DRIVE (OF THE BETA KIND)...... THE PROGRAMMING INTERFACE PINS 2, 3, & 4 ARE USED FOR POWER AND SERIAL OUT AT 19200 8N&1. THE OUTPUT I GOT FROM MY BOARD IS AS FOLLOWS (SOME ADDRESSES REMOVED TO MAKE IT MORE COMPACT): ---------------------------------------------------...
by LEEDNH
Tue Apr 20, 2021 4:48 am
Forum: Modules
Topic: I2C SCANNER
Replies: 13
Views: 658

Re: I2C SCANNER

Hi jerry I am confused about the shift instructions. addr = addr>>3 is this statement okay in SF. shift addr right 3x A statement like addr = addr>>3 seemed to give compile errors when I tried it. Your if I2C.IsPresent(addr << 1) then compiles fine..... You may have fixed another mistake I have been...
by LEEDNH
Tue Apr 20, 2021 4:24 am
Forum: Modules
Topic: I2C SCANNER
Replies: 13
Views: 658

Re: I2C SCANNER

Hi Jerry The reason I started messing with the scanner was because I was having trouble with an I2C INA219 I/V/P MONITORING DEVICE. It would free a pin now used as an analog port to an INA240 HI SIDE ANALOG CURRENT MONITOR. Applying this device has really grown into something I never expected. The i...
by LEEDNH
Mon Apr 19, 2021 11:52 pm
Forum: Modules
Topic: I2C SCANNER
Replies: 13
Views: 658

Re: I2C SCANNER

It works! But, it behaves as if it were in an infinite loop, ignoring the for-next. I noticed the continuous operation when I used 8 bit addresses while trouble shooting... Here are the results (for a scan from $80 to $FE) and code I added to escape from the tendency for infinite repetition .... Sca...
by LEEDNH
Mon Apr 19, 2021 9:49 pm
Forum: Modules
Topic: I2C SCANNER
Replies: 13
Views: 658

Re: I2C SCANNER

I was wondering why the address range was from 0 to 126 as I have used the I2C successfully in the past and always shifted left for the read / write bit, (that's what happens to a copy cat). I had tried the 128 to 254 loop and got a "hit" on every address. I suspected that zero might represent a "sp...
by LEEDNH
Sun Apr 18, 2021 10:40 pm
Forum: Modules
Topic: I2C SCANNER
Replies: 13
Views: 658

I2C SCANNER

I'm back again. I am trying to scan for I2C devices using the function"IsPresent(addr)" from the I2C module. Looking at the "IsPresent(addr)"it seems to do the exact function of verifying that an I2C device exists in the pic's hardware @ addr. I have had limited success in that the code does detect ...
by LEEDNH
Sat Apr 10, 2021 1:43 am
Forum: Modules
Topic: i2c Does not want to show what's on the bus?
Replies: 5
Views: 369

Re: i2c Does not want to show what's on the bus?

Hello Bitfogav Bitfogav, please no need to be apologize for anything... If I had used the processor you specified, it would have worked great. I tend to use the k22 series because I've had relatively good luck with them. I very much appreciate your willingness to share your work, as I am sure many o...
by LEEDNH
Wed Apr 07, 2021 3:08 am
Forum: Modules
Topic: i2c Does not want to show what's on the bus?
Replies: 5
Views: 369

Re: i2c Does not want to show what's on the bus?

THANKS Jerry! I spent some time this past weekend trying to trouble shoot the problem. Even looked at the data pin to make sure it wasn't somehow shorted to ground - nope 10k to Vdd. I did notice the last "public" function in the i2c module " IsPresent(addrs) " and tried it as well. All of the code ...
by LEEDNH
Tue Apr 06, 2021 3:14 am
Forum: Modules
Topic: i2c Does not want to show what's on the bus?
Replies: 5
Views: 369

i2c Does not want to show what's on the bus?

Hello LEEDNH here again ... I thought that I would try out the i2c scanner by bitfogav. The program is a great idea in so far as, if the i2c device isn't found by the scanner, one could rest well assured that sending or receiving data to the device would be a fool's errand... What I did: copied the ...
by LEEDNH
Sun Mar 14, 2021 10:35 pm
Forum: Modules
Topic: SOFTWARE UART - ASM ERRORS
Replies: 9
Views: 453

Re: SOFTWARE UART - ASM ERRORS

Hi Jerry I kind of just fell into using the k22 pics (usually the 2xK22) but also the smaller 14K22 when fewer pins are needed. Thanks very much for the "HEADS UP" as I follow the tried and true engineering maxim regarding the reading of manuals - only after all other options have been exhausted.. J...
by LEEDNH
Sun Mar 14, 2021 7:16 am
Forum: Modules
Topic: SOFTWARE UART - ASM ERRORS
Replies: 9
Views: 453

Re: SOFTWARE UART - ASM ERRORS

Jerry
An update on the SUART... After several hours of back and forth at 19200 the version 1.6 SUART works GREAT!!

Downloaded the Hardware-assisted software uart! Placed them in the library - now we do have FULL DUPLEX!

I'll try to use the FDX next weekend...

Best regards
Lee
by LEEDNH
Sun Mar 14, 2021 12:24 am
Forum: Modules
Topic: SOFTWARE UART - ASM ERRORS
Replies: 9
Views: 453

Re: SOFTWARE UART - ASM ERRORS

Hi Jerry I had a thought about 4 a.m., that I should isolate rx from tx by using a common array but separate FOR-NEXT loops for rx and tx as in half duplex. New code shown below. TNX FOR YOUR SUPPORT!!!! WORKS GREAT!! I guess it could be called looping data the hard way.... "GET 88 BYTES - NO PIANO ...
by LEEDNH
Sat Mar 13, 2021 4:18 am
Forum: Modules
Topic: SOFTWARE UART - ASM ERRORS
Replies: 9
Views: 453

Re: SOFTWARE UART - ASM ERRORS

I am still having problems with the SUART.....THE CODE ASSEMBLES JUST FINE! I USED A COUPLE DIFFERENT SERIAL TERM PGMS REAL TERM SEEMS TO WORK OK, OR AT LEAST BETTER THAN SOME OTHERS GENERALLY. DUH - THEN I REMEMBERED THAT SF HAS A BUILT IN SERIAL TERM WHICH WORKS BEST.... AS A WAY TO TROUBLE SHOOT ...
by LEEDNH
Mon Mar 01, 2021 5:44 am
Forum: General
Topic: interested in new device support?
Replies: 12
Views: 1354

Re: interested in new device support?

Hi Jerry
I'll bet the data sheet reads better than Crime and Punishment!
I SEE SOME SERIOUS READING IN MY FUTURE...
TIME TO TRY OUT THE PIN ASSIGNMENT PROGRAM.
Maybe I will learn enough to play with the K42...
Regards
Lee