Libstock
It is currently 25 Oct 2014 23:04

All times are UTC + 1 hour




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: 06 Mar 2012 16:13 
Offline

Joined: 20 Dec 2011 21:54
Posts: 4
Hello,

I’m building now a small MikroC program that reads (via I²C bus) data from an accelerometer --- this part is OK, works fine---, and I want to complete my program by allowing a PLC programmer to read those accelerometer data via Modbus RS-485.

My data (from accelero.) array is 7-bytes long, so I know I cannot use the standard MikroC RS-485 library.

**Would you have an example of MikroC code (or even MikroBasic) that could help me in this small application?

I suppose we have to build our array according to the Modbus protocol, but at this point, I’m quite confused (w/ CRC frame, etc.). Feel free for any help,

NOTA: I' using a Pic18F258. I already have a MAX485 driver. I certainly need to set a 485 address to this MCU, and by this address, I want the PLC user get access to the 7 data (ex: X-axis value, Y-axis-Value, Status byte …).

Thank you,
CaptDans


Top
 Profile  
 
PostPosted: 07 Mar 2012 10:26 
Offline
mikroElektronika team
User avatar

Joined: 25 Jan 2008 09:56
Posts: 7912
Hi,

I would like to help you, but our support team is very busy trying to get to every single support request on forum, as well as on our support tickets.
I recommend you to read your chip's datasheet and see how to manage your issue and try writing the code by yourself.
Also, try searching throughout the forum topics, there may be a piece of code you are looking for.

Thank you for the understanding.

Regards,
Filip.


Top
 Profile  
 
PostPosted: 14 Mar 2014 16:23 
Offline

Joined: 27 Feb 2014 19:23
Posts: 1
Hello Captdans,
we wait you are doing well.

Please, would you send us your MikroC code for us to build a small MikroC program that reads (via I²C bus) data from the type of accelerometer that you are using :D ?

Many thanks for advance.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: Google [Bot] and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group