if you can define what a trendline is then someone can write this software. Unfortunately, technical analysis signals are in the eye of the beholder. :D
"""
NYSE,ibm,108.22,BUY,400
SMART,msft,38.36,BUY,300
"""
f=open('c:/tmp/orders.txt')
for x in f.readlines():
v=x.split(',')
order = Order(v)
twsclient.placeOrder(order)
PM me if you want the Order() and twsclient code