Hello,
In your project options please can you turn off the Auto clear watchdog setting. The watchdog isn't running so these are a load of instructions that aren't required.
Also I would highly recommend disabling the Low Voltage Programming setting unless you are specifically using it. This can cause a stack of issues. e.g. freezing, self erase etc.
If these don't help then you could also try running the chip at a lower frequency and see if that resolves the problem. As a test maybe try 16MHz - OSCFRQ = 0x05; Remember to also update the frequency in the project options.
Modbus TCP Slave
-
- Matrix Staff
- Posts: 1882
- http://meble-kuchenne.info.pl
- Joined: Mon Dec 07, 2020 10:06 am
- Has thanked: 484 times
- Been thanked: 661 times
Re: Modbus TCP Slave
Regards Ben Rowland - MatrixTSL
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel
Re: Modbus TCP Slave
problem
Modbus Master: FC10 Simulator, Modbus Poll
Modbus slave: PIC18F67K40, PIC24FJ512GA606
1. When retrieving data, up to 8 data are operated stably in FC10, and only 1 data is operated stably in Modbus Poll.
More than 10 will not work.
2. When importing data, the return value is
Occasionally repeats 0,1. (FC10)
Repeat read error, write error. (Modbus Poll)
If 255 is returned, the slave device is hung up. After resetting the slave device, it restarts successfully.
Sometimes I get 255 and it works fine after a while.
Sometimes it stops after about 10 minutes.
Even if I test the above by changing various options, I get the same results.
Please Help me!
Thank you.
Modbus Master: FC10 Simulator, Modbus Poll
Modbus slave: PIC18F67K40, PIC24FJ512GA606
1. When retrieving data, up to 8 data are operated stably in FC10, and only 1 data is operated stably in Modbus Poll.
More than 10 will not work.
2. When importing data, the return value is
Occasionally repeats 0,1. (FC10)
Repeat read error, write error. (Modbus Poll)
If 255 is returned, the slave device is hung up. After resetting the slave device, it restarts successfully.
Sometimes I get 255 and it works fine after a while.
Sometimes it stops after about 10 minutes.
Even if I test the above by changing various options, I get the same results.
Please Help me!
Thank you.
Re: Modbus TCP Slave
It still doesn't work.
Of course, the FC10 program you sent me sometimes loads data.
However, many other programs can't load data via Modbus TCP. The port scan program doesn't recognize port 502 either.
I tried hard for many days but failed.
I think the library of fC10 is wrong.
If it can't load from various programs, isn't it the problem of FC10?
Or please read it from another program and reply.
Please.
Thank you.
Of course, the FC10 program you sent me sometimes loads data.
However, many other programs can't load data via Modbus TCP. The port scan program doesn't recognize port 502 either.
I tried hard for many days but failed.
I think the library of fC10 is wrong.
If it can't load from various programs, isn't it the problem of FC10?
Or please read it from another program and reply.
Please.
Thank you.
-
- Matrix Staff
- Posts: 1882
- Joined: Mon Dec 07, 2020 10:06 am
- Has thanked: 484 times
- Been thanked: 661 times
Re: Modbus TCP Slave
Hello,
Please can you post your latest project file and I'll do what I can to try and replicate the issue.
Please can you post your latest project file and I'll do what I can to try and replicate the issue.
Regards Ben Rowland - MatrixTSL
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel
Re: Modbus TCP Slave
Thank you for your interest
I'm posting my last project here.
For reference, I tried using ModbusTCP Master, but it doesn't communicate.
When I reset, port 502 is searched for a while, but after a few seconds, it is not searched.
Thank you.
I'm posting my last project here.
For reference, I tried using ModbusTCP Master, but it doesn't communicate.
When I reset, port 502 is searched for a while, but after a few seconds, it is not searched.
Thank you.
- Attachments
-
- Hub-240920-18F67K40-TCP -1.fcfx
- (120.02 KiB) Not downloaded yet