Search found 55 matches

by lexicon
Wed Nov 14, 2018 12:26 pm
Forum: Flowcode V5 Issues
Topic: PIC18F66K80 - Confused by UART config
Replies: 3
Views: 5919

Re: PIC18F66K80 - Confused by UART config

Hi Ben,

No, not yet, although that is the obvious thing to do - I will try it and see.
The thing that got me was that 3 out of 4 pins seem to work, regardless of the config file seemingly being wrong for all of them....

Cheers,
Martin.
by lexicon
Wed Nov 14, 2018 10:12 am
Forum: Flowcode V5 Issues
Topic: PIC18F66K80 - Confused by UART config
Replies: 3
Views: 5919

PIC18F66K80 - Confused by UART config

I'm updating an old project written on FC5 and I needed to add a 2nd serial port to receive data from an RF device on UART2. I'm already using UART1 with no issues. Although I can transmit data out of TX2, I cannot receive anything on RX2 - the receive line seems to be held permanently high. So, I h...
by lexicon
Wed Jun 20, 2018 5:28 pm
Forum: 16-Bit PIC
Topic: CAN bus speed on dsPIC33EP512GM710
Replies: 6
Views: 8261

Re: CAN bus speed on dsPIC33EP512GM710

I've had time to have another look at this, so I wrote my own bit of config code which I call after the FC CAN init macro. The speed is now correct at 500kbps using 16MHz clock (although the first time it was half speed and I had to change the CANCKS bit, so maybe this device does have that issue af...
by lexicon
Wed Jun 20, 2018 4:54 pm
Forum: Flowcode V5 Issues
Topic: PIC18F66K80 - RA5 not selectable
Replies: 2
Views: 5067

Re: PIC18F66K80 - RA5 not selectable

Yep, that appears to have done the trick - thanks.
by lexicon
Wed Jun 20, 2018 4:22 pm
Forum: Flowcode V5 Issues
Topic: PIC18F66K80 - RA5 not selectable
Replies: 2
Views: 5067

PIC18F66K80 - RA5 not selectable

I know it's an old product now, but I'm working on updates to a project that was originally developed on FC5 and I decided to stick with it rather than move it to FC7. Anyway, using a PIC 18F66K80, I'm not able to select RA5 as an input (connecting to a switch) as it is missing from the select list....
by lexicon
Tue May 01, 2018 8:54 am
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

Hi Ben, To be honest, no, I don't think it would be beneficial to me - I don't need the faster sample time or anything like that. I was just curious as to whether it should be selectable. Having looked at the help page it does say it will be the maximum the device supports, but I hadn't read that be...
by lexicon
Mon Apr 30, 2018 12:24 pm
Forum: 16-Bit PIC
Topic: dsPIC33EP512GM710 UART Interrupt warning
Replies: 1
Views: 4793

dsPIC33EP512GM710 UART Interrupt warning

When using the UART RX interrupt I see the following message during compilation: In function '_U1RXInterrupt': coff-cc1.exe: warning: _U1RXInterrupt PSV model not specified for '_U1RXInterrupt'; assuming 'auto_psv' this may affect latency Not sure if this is significant or not as the interrupt works...
by lexicon
Mon Apr 30, 2018 12:15 pm
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

One thing I've noticed is that, although the ADC supports 10 or 12 bit conversion, the bit depth is fixed at 12 in the Properties selector.
by lexicon
Mon Apr 23, 2018 9:16 am
Forum: 16-Bit PIC
Topic: CAN bus speed on dsPIC33EP512GM710
Replies: 6
Views: 8261

Re: CAN bus speed on dsPIC33EP512GM710

Hi J,
Yes I had seen that but, according to the errata sheet, this device doesn't have that issue.
by lexicon
Wed Apr 18, 2018 3:51 pm
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

At least two other ADC channels are also working, so that looks good - thanks Ben.
by lexicon
Wed Apr 18, 2018 2:12 pm
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

Thanks Ben, first impressions are good, it certainly works with the test code.
I'll try it out on my actual project as soon as I can.

Regards,
Martin.
by lexicon
Wed Apr 18, 2018 12:37 pm
Forum: 16-Bit PIC
Topic: CAN bus speed on dsPIC33EP512GM710
Replies: 6
Views: 8261

Re: CAN bus speed on dsPIC33EP512GM710

I'm still struggling with the CAN bus speed. You'll have to bear with me here on what seems like a complicated test, but I have to use the hardware project I've got - I've cut out the extraneous stuff as much as possible. I have an RF transceiver chip that reads a keyfob and sends the received key i...
by lexicon
Wed Apr 18, 2018 8:39 am
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

Hi Leigh,

Have you any thoughts on why I can't get the ADC to work directly in Flowcode?
Ultimately I need to have quite a few ADC channels working and I'd much rather not have to code it in C.
by lexicon
Thu Apr 05, 2018 4:47 pm
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

So I finally got around to looking a bit deeper into my ADC issue. I couldn't seem to get anywhere playing with timings etc within Flowcode, so I cobbled together some C code in MPLAB and I was able to flash a LED at a variable rate set by a pot - at least I know the hardware works. I've imported th...
by lexicon
Mon Mar 05, 2018 11:18 am
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

OK Leigh, thanks.
I've tried some different timings but didn't make any difference - I'll have to look into it more closely, that will probably be in a few days.

What was the bug that the newest FCD fixed?
by lexicon
Thu Mar 01, 2018 5:02 pm
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

Thanks Leigh & Ben - yes, that seems to have fixed the port E initialisation. Can you offer any suggestions regarding my ADC read seemingly always returning 0 as per my opening post? I've tried a couple of different channels (namely, AN2,3 & 8 as I can easily attach a pot to those on the board) and ...
by lexicon
Thu Mar 01, 2018 2:52 pm
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

Hi Ben, I now get the following error: C:\Program Files (x86)\Flowcode 7\CAL\/PIC16BIT\PIC16BIT_CAL_CAN.c:43:3: error: #error "Internal CAN not supported on this device" I think you might have started with an old version as per this thread? https://www.matrixtsl.com/mmforums/viewtopic.php?f=64&t=19490
by lexicon
Wed Feb 21, 2018 6:19 pm
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

Re: ADC oddness on dsPIC33EP512GM710

I've been doing a bit more investigation on the incorrect B8 output. It seems it's not the output to port B8 but reading from E13, this always presents a low state until I do an ADC read, then it works correctly. The attached program works fine in sim - operating the input switch E13 selects the out...
by lexicon
Wed Feb 21, 2018 3:47 pm
Forum: 16-Bit PIC
Topic: CAN bus speed on dsPIC33EP512GM710
Replies: 6
Views: 8261

Re: CAN bus speed on dsPIC33EP512GM710

Hi QMESAR and thanks for your input. I agree oscillator config would be the first candidate and that was the reason I included a timed heartbeat. My heartbeat pulse scopes at the expected 10ms which implies to me that the clock speed is correct. Are you sure you have to manually code the oscillator ...
by lexicon
Fri Feb 16, 2018 5:11 pm
Forum: 16-Bit PIC
Topic: CAN bus speed on dsPIC33EP512GM710
Replies: 6
Views: 8261

CAN bus speed on dsPIC33EP512GM710

Having configured the CAN interface at 500kbs on the dsPIC33EP512GM710, I'm finding that the actual transmission speed is more like 400kbs and I'm not sure why. This is part of the same project as referred to in this thread https://www.matrixtsl.com/mmforums/viewtopic.php?f=69&t=19842 regarding the ...
by lexicon
Fri Feb 16, 2018 3:40 pm
Forum: 16-Bit PIC
Topic: ADC oddness on dsPIC33EP512GM710
Replies: 18
Views: 13155

ADC oddness on dsPIC33EP512GM710

Hi, I've been working on a project using the dsPIC33EP512GM710. All has been going reasonably well until I try to use some ADC inputs. When reading from AN2 or AN3 (the only ones I'm currently using) I always seem to get 0. I've stripped down my program to a simple test that reads AN3 and outputs th...
by lexicon
Mon Nov 13, 2017 11:34 am
Forum: Bug reports
Topic: dsPIC33EP512GM710 config anomalies
Replies: 5
Views: 3498

Re: dsPIC33EP512GM710 config anomalies

Ah, I didn't know that - thanks.
by lexicon
Fri Nov 10, 2017 12:36 pm
Forum: Bug reports
Topic: dsPIC33EP512GM710 config anomalies
Replies: 5
Views: 3498

Re: dsPIC33EP512GM710 config anomalies

Hi Ben,
Those 2 issues look fine now - thanks.

Can you take a look at the config of the PWM channels please?
There should be 12, but only 8 seem to be defined, and none of the output pins match.

Regards,
Martin.
by lexicon
Mon Nov 06, 2017 10:18 am
Forum: Bug reports
Topic: dsPIC33EP512GM710 config anomalies
Replies: 5
Views: 3498

Re: dsPIC33EP512GM710 config anomalies

I had a look in the config file and I see:

<pin name='AN38 / RD14' port='3' bit='10' adc='38' />
<pin name='AN39 / RD15' port='3' bit='11' adc='39' />

which probably explains the mis-configuration of those pins.

However, I could not find any configuration pertaining to the ECAN.
by lexicon
Thu Nov 02, 2017 10:51 am
Forum: Bug reports
Topic: dsPIC33EP512GM710 config anomalies
Replies: 5
Views: 3498

dsPIC33EP512GM710 config anomalies

Hi, I've just started with the dsPIC33EP512GM710 on FC7 (I'm new to both having only used 8 bit devices on FC5 previously). I think I've found a couple of device configuration issues: 1) When configuring I/O to ports RD14 & RD15 using the graphic selector, these actually map to RD10 (RD_H2) & RD11 (...