Skip to content

Please Help #7

Description

@Jono72

I am to say a novice, but withstanding I've learnt a lot whilst developing my project, I have an Atmel 1284P currently running a Modbus RTU slave stack that works very nicely. I want to attempt to use the BACnet

stack over MSTP, Mac address and instance ID, baud etc will all be configured from a small config file on an SD card.
My current application is written using Arduino C (in visual studio), I have tried to create a simple Bacnet net test and tried to compile it, I cannot however get it to compile, I have modified the hardware.h file
#ifndef HARDWARE_H
#define HARDWARE_H

#if !defined(F_CPU)
/* The processor clock frequency */
#define F_CPU 7372800UL
#endif

#if defined(IAR_SYSTEMS_ICC) || defined(IAR_SYSTEMS_ASM)|| (ICCAVR)
#include <iom1284p.h>
#else
#if !defined(AVR_ATmega1284P)
#error Firmware is configured for ATmega1284 only (-mmcu=atmega1284p)
#endif
#endif
#include "iar2gcc.h"
#include "avr035.h"

#define LED_NPDU_INIT() BIT_SET(DDRD, DDD5)
#define LED_NPDU_ON() BIT_CLEAR(PORTD, PD5)
#define LED_NPDU_OFF() BIT_SET(PORTD, PD5)
/* #define LED_NPDU PORTD_Bit5 /
/
#define LED_NPDU_OFF() {LED_NPDU = false;} /
/
#define LED_NPDU_ON() {LED_NPDU = true;} */

#define LED_GREEN_INIT() BIT_SET(DDRD, DDD4)
#define LED_GREEN_ON() BIT_CLEAR(PORTD, PD4)
#define LED_GREEN_OFF() BIT_SET(PORTD, PD4)

#endif

And this is the main application with the includes, I haven't written any code yet I just want to get the Stack to compile first, can anybody help me out here?

#include <ai.h>
#include <av.h>
#include <avr035.h>
#include <bv.h>
#include <device.h>
#include <hardware.h>
#include <iar2gcc.h>
#include <rs485.h>
#include <stack.h>
#include <stdbool.h>
#include <stdint.h>
#include <timer.h>

void setup() {
// put your setup code here, to run once:

}

void loop() {
// put your main code here, to run repeatedly:

}

I just want to use Bacnet over MSTP that's it.

Regards

John

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions