Comments (8)
Thank you for the issue
from arduinomodbusslave.
Update: I try to re-sort my fork into different branches ...
- issue98: is the fix where this issue is about.
The rest goes way beyond this ...
-
kernel: A class which already provides some which I would expect from any of my workable slaves.
The idea is to have a consistent set of kernel functionality and code the dedicated application functions in a derived class. -
kernel-examples: Examples using the above concept.
-
allnew: Merging all of the above
-
EP32: Will finally only contain the addition in library.properties file. ESP32 architecture is currently not listed, but the library seems to work.
from arduinomodbusslave.
hi Werner
thanks for good issue.
please tag simpleESP32.ino.
text is not correct to open.
from arduinomodbusslave.
Hi Erfan, sorry for not exactly understanding your message ...
Do you have issues when trying to open attached simpleESP32.ino.txt ?
Of course it needs to be renamed after download. I took the .txt naming by intention to get only a quick preview in text editor when clicking on it (avoid immediate start of Arduino IDE). As mentioned, I'm still a Github newbie ...
btw: In the meantime I re-organized my fork https://github.com/tinkering4fun/ArduinoModbusSlave-ESP32-fork
See branch 'specific-examples' and example 'plainSlave'
ArduinoModbusSlave-ESP32-fork/examples/specific/ESP32/plainSlave
from arduinomodbusslave.
thanks dear Werner
I want to put an ESP32 module as a slave by Yaacov's library (Modbusslave.h) and read the analog data by Modbus pull in my pc.
can you help me?
from arduinomodbusslave.
dear Werner.
Does this library (Modbusslave.h) work on STM32 (bule pill)?
from arduinomodbusslave.
Hi Erfan,
i guess my mentioned example ArduinoModbusSlave-ESP32-fork/examples/specific/ESP32/plainSlave
does exactly what you asked for ...?
See line 445
slave->writeRegisterToBuffer(i, analogRead(adc_pins[address + i]));
I assume you are already familiar with Modbus and have some Modbus client software at your PC-
If so, just use FC04 to read the input registers 0 and 1, which will return the values from pins ADC_0 and ADC_1.
There is also a straight-forward and simple example in Yaacov's lib
ArduinoModbusSlave/examples/simple
It is made for Arduino board, but the code should also run on ESP32 after changing the ADC pin definitions.
Just 150 lines of code, so it should be a good starter.
I never used STM32, if you own one, just give it a try and see ...
btw:
If you never used Modbus before, it may be too complex to learn for just just pulling ADC values into an PC.
Sorry, but I will not guide you to a final Modbus end to end solution for your specific problem.
Hope this helped to some extend.
Regards
Werner
from arduinomodbusslave.
Thanks dear Werner.
yes, i used Yaacov's lib and read analog on Modbus pull.
i could use from Yaakov's library on ESP32 with your guide. very good issue.
thank you and dear Dr zemir
Regards
Erfan
from arduinomodbusslave.
Related Issues (20)
- ModBusSlave delivers bytes instead of words on FC03 How to fix ? HOT 4
- Strange behiavor on slave using write single register HOT 9
- Stuck when calling flush() in begin() when using Serial1 in Arduino MKR(Zero) HOT 2
- Not working with I2C communication HOT 9
- Enable / disable communication HOT 2
- Arduino Mudbus RTU for MASTER to read/write for multi slave ?
- change Slave_ID in void setup() HOT 2
- Put data in a specific address HOT 1
- using a modbus master simulator software with this library HOT 10
- Exception Response , Illegal Data Address HOT 1
- linux modpoll HOT 1
- Change SLAVE ADDRESS during void setup HOT 1
- Hello how can i read data from 40001 HOT 1
- hi i am getting modbus poll pc application timeout error Could you please help me HOT 1
- Modbus Slave RP2 HOT 2
- 怎么设置 数据位 停止位
- Arduino Pro Micro
- Create new release HOT 4
- Character silent interval issue and Buffer overrun HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arduinomodbusslave.