Skip to content
Snippets Groups Projects
Commit a74df630 authored by Prashant Patil's avatar Prashant Patil
Browse files

more documentaiton

parent 1f263c84
No related branches found
No related tags found
No related merge requests found
Pipeline #
Showing with 170 additions and 59 deletions
No preview for this file type
No preview for this file type
......@@ -191,7 +191,7 @@ const USB_Descriptor_String_t PROGMEM ManufacturerString = USB_STRING_DESCRIPTOR
* and is read out upon request by the host when the appropriate string ID is requested, listed in the Device
* Descriptor.
*/
const USB_Descriptor_String_t PROGMEM ProductString = USB_STRING_DESCRIPTOR(L"LUFA USB-RS232 Adapter");
const USB_Descriptor_String_t PROGMEM ProductString = USB_STRING_DESCRIPTOR(L"FabFTDI");
/** This function is called by the library when in device mode, and must be overridden (see library "USB Descriptors"
* documentation) by the application code so that the address and size of a requested descriptor can be given
......
File moved
FabFTDI Readme
File moved
File moved
File moved
#
# LUFA Library
# Copyright (C) Dean Camera, 2017.
#
# dean [at] fourwalledcubicle [dot] com
# www.lufa-lib.org
#
# --------------------------------------
# LUFA Project Makefile.
# --------------------------------------
# Run "make help" for target help.
MCU = atmega16u2
ARCH = AVR8
BOARD = NONE
F_CPU = 16000000
F_USB = $(F_CPU)
OPTIMIZATION = s
TARGET = USBtoSerial
SRC = $(TARGET).c Descriptors.c $(LUFA_SRC_USB) $(LUFA_SRC_USBCLASS)
LUFA_PATH = ../LUFA
CC_FLAGS = -DUSE_LUFA_CONFIG_HEADER -IConfig/
LD_FLAGS =
# Default target
all:
# Include LUFA-specific DMBS extension modules
DMBS_LUFA_PATH ?= $(LUFA_PATH)/Build/LUFA
include $(DMBS_LUFA_PATH)/lufa-sources.mk
include $(DMBS_LUFA_PATH)/lufa-gcc.mk
# Include common DMBS build system modules
DMBS_PATH ?= $(LUFA_PATH)/Build/DMBS/DMBS
include $(DMBS_PATH)/core.mk
include $(DMBS_PATH)/cppcheck.mk
include $(DMBS_PATH)/doxygen.mk
include $(DMBS_PATH)/dfu.mk
include $(DMBS_PATH)/gcc.mk
include $(DMBS_PATH)/hid.mk
include $(DMBS_PATH)/avrdude.mk
include $(DMBS_PATH)/atprogram.mk
File moved
File moved
......@@ -5,22 +5,55 @@
# dean [at] fourwalledcubicle [dot] com
# www.lufa-lib.org
#
# --------------------------------------
# LUFA Project Makefile.
# --------------------------------------
# Makefile to build the LUFA library, projects and demos.
# Run "make help" for target help.
# Call with "make all" to rebuild everything, "make clean" to clean everything,
# "make mostlyclean" to remove all intermediary files but preserve any binaries,
# "make doxygen" to document everything with Doxygen (if installed). Call
# "make help" for additional target build information within a specific project.
MCU = atmega16u2
ARCH = AVR8
BOARD = NONE
F_CPU = 16000000
F_USB = $(F_CPU)
OPTIMIZATION = s
TARGET = USBtoSerial
SRC = $(TARGET).c Descriptors.c $(LUFA_SRC_USB) $(LUFA_SRC_USBCLASS)
LUFA_PATH = ./LUFA
CC_FLAGS = -DUSE_LUFA_CONFIG_HEADER -IConfig/
LD_FLAGS =
# Default target
all:
%:
@echo Executing \"make $@\" on all LUFA library elements.
@echo
$(MAKE) -C LUFA $@
$(MAKE) -C Demos $@
$(MAKE) -C Projects $@
$(MAKE) -C Bootloaders $@
@echo
@echo LUFA \"make $@\" operation complete.
# Include LUFA-specific DMBS extension modules
DMBS_LUFA_PATH ?= $(LUFA_PATH)/Build/LUFA
include $(DMBS_LUFA_PATH)/lufa-sources.mk
include $(DMBS_LUFA_PATH)/lufa-gcc.mk
# Include common DMBS build system modules
DMBS_PATH ?= $(LUFA_PATH)/Build/DMBS/DMBS
include $(DMBS_PATH)/core.mk
include $(DMBS_PATH)/cppcheck.mk
include $(DMBS_PATH)/doxygen.mk
include $(DMBS_PATH)/dfu.mk
include $(DMBS_PATH)/gcc.mk
include $(DMBS_PATH)/hid.mk
include $(DMBS_PATH)/avrdude.mk
include $(DMBS_PATH)/atprogram.mk
# Programming
program-avrisp2: $(TARGET).hex
avrdude -p m16u2 -P usb -c avrisp2 -U flash:w:$(TARGET).hex
program-avrisp2-fuses: $(TARGET).hex
avrdude -p m16u2 -P usb -c avrisp2 -U lfuse:w:0x5E:m
program-usbtiny: $(TARGET).hex
avrdude -p m16u2 -P usb -c usbtiny -U flash:w:$(TARGET).hex
program-usbtiny-fuses: $(TARGET).hex
avrdude -p m16u2 -P usb -c usbtiny -U lfuse:w:0x5E:m
#!/usr/bin/env python
#
# term.py
#
# term.py serial_port port_speed
#
# Neil Gershenfeld
# CBA MIT 7/27/07
#
# (c) Massachusetts Institute of Technology 2007
# This work may be reproduced, modified, distributed,
# performed, and displayed for any purpose. Copyright is
# retained and must be preserved. The work is provided
# as is; no warranty is provided, and users accept all
# liability.
#
import sys,time,serial
from Tkinter import *
from select import *
NROWS = 25
NCOLS = 80
def key(event):
#
# key press event handles
#
key = event.char
#print 'send',ord(key)
if (ord(key) == 13):
key = chr(10)
ser.write(key)
def quit():
#
# clean up and quit
#
sys.exit()
def idle(parent):
#
# idle loop
#
wait = ser.inWaiting()
if (wait != 0):
#
# read character
#
byte = ser.read()
widget_text.config(state=NORMAL)
#print byte,ord(byte)
if (ord(byte) == 10):
#
# CR
#
widget_text.insert(INSERT,'\n')
if (int(float(widget_text.index(END))) > (NROWS+1)):
widget_text.delete(1.0,2.0)
#if (ord(byte) == 13):
#
# CR
#
#widget_text.insert(INSERT,'\n')
#if (int(float(widget_text.index(END))) > (NROWS+1)):
# widget_text.delete(1.0,2.0)
elif (byte == 8):
#
# BS
#
widget_text.delete(INSERT+"-1c",INSERT)
else:
#
# character
#
widget_text.insert(INSERT,byte)
widget_text.config(state=DISABLED)
time.sleep(0.001)
parent.after_idle(idle,parent)
#
# check command line arguments
#
if (len(sys.argv) != 3):
print "command line: term.py serial_port speed"
sys.exit()
port = sys.argv[1]
speed = int(sys.argv[2])
#
# open serial port
#
ser = serial.Serial(port,speed)
ser.setDTR()
#
# flush buffers
#
ser.flushInput()
ser.flushOutput()
#
# set up UI
#
root = Tk()
root.bind('<Key>',key)
root.title('term.py')
#
widget_quit = Button(root, text="quit",command=quit)
widget_quit.pack()
#
address_frame = Frame(root)
Label(address_frame,text="port: "+port).pack(side='left')
Label(address_frame,text=" speed: "+str(speed)).pack(side='left')
address_frame.pack()
#
widget_text = Text(root, bg='white', bd=5, width=NCOLS, height=NROWS, font=('arial',10,'bold'))
#widget_text.bind('<Key>',key)
widget_text.config(state=DISABLED)
widget_text.pack()
#
# begin event loop
#
root.after(100,idle,root)
root.mainloop()
index_files/FabFTDI_Mac.png

291 KiB

index_files/FabFTDI_listed.png

99.8 KiB

index_files/FabFTDI_notlisted.png

89.5 KiB

0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment